T
The type to which the value returned from the storage / cache is given.
Platform Core .NET Assemblies API
GetValue<T>(IBaseStore,String,T) Method
See Also  Send Feedback
Terrasoft.Core.Store Namespace > CacheStoreUtilities Class > GetValue Method : GetValue<T>(IBaseStore,String,T) Method
source
Data storage or cache.
key
Key of the value.
defaultValue
The default value that will be returned of the method if the value by key was not found in the storage/cache.

Glossary Item Box

Gets the value by the key key from the data storage or cache and casts the obtained value to the specified type. If no key value is found, the method returns the specified default value.

Syntax

 
C#
 
 

Parameters

source
Data storage or cache.
key
Key of the value.
defaultValue
The default value that will be returned of the method if the value by key was not found in the storage/cache.

Type Parameters

T
The type to which the value returned from the storage / cache is given.

Return Value

The by the key key casted to the T type or defaultValue if the value is not found.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

© Terrasoft 2002-2018.